package com.ll.blog.mapper;

import com.ll.blog.entity.Relevancy;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ll.blog.entity.Tag;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author 作者
 * @since 2024-03-02
 */
public interface RelevancyMapper extends BaseMapper<Relevancy> {
    @Select("SELECT b.id ,b.name  from relevancy as a  LEFT JOIN tag as b  on a.tag_id = b.id  WHERE a.article_id=#{ArticleId}")
    List<Tag> getTagList(Integer ArticleId);

}
